package alo.p3.work;

import alo.p3.ListNode;
//判断链表的长度是偶数还是奇数
public class IsLinkedListLengthEven {
    int InsertInSortedList(ListNode headNode){
        while (headNode.getNext()!=null&&headNode.getNext().getNext()!=null){
            headNode=headNode.getNext().getNext();
        }
        if (headNode.getNext()==null)
            return 1;
        else
            return 0;
    }
}
